
package com.zsrt.day20170505.ch05;


import org.junit.Test;

public class BTreeTest {

	@Test
	public void testName() throws Exception {
		
		
		Node root= new Node(5);
		
		BTree tree = new BTree(root);
		
		Node node1= new Node(3);
		Node node2= new Node(7);
		Node node3= new Node(6);
		Node node4= new Node(8);
		Node node5= new Node(2);
		Node node6= new Node(4);
		
		tree.add(root, node1);
		tree.add(root, node2);
		tree.add(root, node3);
		tree.add(root, node4);
		tree.add(root, node5);
		tree.add(root, node6);
		
		System.out.println(tree);
		
		tree.preOrder(root);
		System.out.println();
		tree.inOrder(root);
	}
}
